<?xml version="1.0" encoding="utf-8"?>
<!--
                                                                                     
 h       t     t                ::       /     /                     t             / 
 h       t     t                ::      //    //                     t            // 
 h     ttttt ttttt ppppp sssss         //    //  y   y       sssss ttttt         //  
 hhhh    t     t   p   p s            //    //   y   y       s       t          //   
 h  hh   t     t   ppppp sssss       //    //    yyyyy       sssss   t         //    
 h   h   t     t   p         s  ::   /     /         y  ..       s   t    ..   /     
 h   h   t     t   p     sssss  ::   /     /     yyyyy  ..   sssss   t    ..   /     
                                                                                     
	<https://y.st./>
	Copyright © 2016 Alex Yst <mailto:copyright@y.st>

	This program is free software: you can redistribute it and/or modify
	it under the terms of the GNU General Public License as published by
	the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.

	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
	GNU General Public License for more details.

	You should have received a copy of the GNU General Public License
	along with this program. If not, see <https://www.gnu.org./licenses/>.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<base href="https://y.st./en/weblog/2016/05-May/02.xhtml" />
		<title>Switching email clients (again) &lt;https://y.st./en/weblog/2016/05-May/02.xhtml&gt;</title>
		<link rel="icon" type="image/png" href="/link/CC_BY-SA_4.0/y.st./icon.png" />
		<link rel="stylesheet" type="text/css" href="/link/basic.css" />
		<link rel="stylesheet" type="text/css" href="/link/site-specific.css" />
		<script type="text/javascript" src="/script/javascript.js" />
		<meta name="viewport" content="width=device-width" />
	</head>
	<body>
		<nav>
			<p>
				<a href="/en/">Home</a> |
				<a href="/en/a/about.xhtml">About</a> |
				<a href="/en/a/contact.xhtml">Contact</a> |
				<a href="/a/canary.txt">Canary</a> |
				<a href="/en/URI_research/"><abbr title="Uniform Resource Identifier">URI</abbr> research</a> |
				<a href="/en/opinion/">Opinions</a> |
				<a href="/en/coursework/">Coursework</a> |
				<a href="/en/law/">Law</a> |
				<a href="/en/a/links.xhtml">Links</a> |
				<a href="/en/weblog/2016/05-May/02.xhtml.asc">{this page}.asc</a>
			</p>
			<hr/>
			<p>
				Weblog index:
				<a href="/en/weblog/"><abbr title="American Standard Code for Information Interchange">ASCII</abbr> calendars</a> |
				<a href="/en/weblog/index_ol_ascending.xhtml">Ascending list</a> |
				<a href="/en/weblog/index_ol_descending.xhtml">Descending list</a>
			</p>
			<hr/>
			<p>
				Jump to entry:
				<a href="/en/weblog/2015/03-March/07.xhtml">&lt;&lt;First</a>
				<a rel="prev" href="/en/weblog/2016/05-May/01.xhtml">&lt;Previous</a>
				<a rel="next" href="/en/weblog/2016/05-May/03.xhtml">Next&gt;</a>
				<a href="/en/weblog/latest.xhtml">Latest&gt;&gt;</a>
			</p>
			<hr/>
		</nav>
		<header>
			<h1>Switching email clients (again)</h1>
			<p>Day 00422: Monday, 2016 May 02</p>
		</header>
<p>
	Fearing that the high school might deny my transcript request based on my home address not matching the address on my photo <abbr title="identification">ID</abbr>, I made a copy of the change-of-address label sent to me by the <abbr title="Department of Motor Vehicles">DMV</abbr>, cut it out, then copied my <abbr title="identification">ID</abbr> with the label copy applied.
	I biked down to the post office to get it mailed, so now all I can do as far as school is concerned is wait.
</p>
<p>
	A while back, Chris Zabriskie gave me his albums that he released under the name <a href="http://chriszabriskie.com./lofi/">Lo-Fi is Sci-Fi</a>, but due to not coming through the usual channels, they are in <abbr title="MPEG-1 or MPEG-2 Audio Layer III">MP3</abbr> format and without cover art.
	Today, I tracked down the cover art.
	I got it from the Free Music Archive, though I won&apos;t link to them due to being behind a CloudFlare <abbr title="Completely Automated Public Turing test to tell Computers and Humans Apart">CAPTCHA</abbr> wall.
	The Lo-Fi is Sci-Fi albums and artist profile have been deleted from the website, but the individual tracks are still accessible.
	The cover art isn&apos;t linked to in any findable way, but <a href="https://3g2upl4pq6kufc4m.onion/?q=Lo-Fi+is+Sci-Fi+O+Great+Queen+Electric%2C+What+Do+You+Have+Waiting+for+Me%3F&amp;t=ffsb&amp;iax=1&amp;ia=images">DuckDuckGo</a> found all four album covers when I searched for the cover of &quot;O Great Queen Electric, What Do You Have Waiting for Me?&quot;.
	If someone reading this has <abbr title="Free Lossless Audio Codec">FLAC</abbr> files, I&apos;m still looking for those.
	Unfortunately, Chris removed the Bandcamp page, so we can&apos;t just buy <abbr title="Free Lossless Audio Codec">FLAC</abbr> files there.
</p>
<p>
	The name &quot;Pinentry&quot; has always been strange in my mind, though now I think that I know what it means: &quot;<abbr title="personal identification number">PIN</abbr> entry&quot;; I found a page that calls it <a href="http://www.linuxfromscratch.org./blfs/view/stable/general/pinentry.html">&quot;pin-entry&quot;</a>.
	Speaking of which, I managed to track down instructions for <a href="https://tr.opensuse.org./SDB:Using_gpg-agent">making Pinentry less annoying</a>.
	In addition to making <abbr title="GNU Privacy Guard">GnuPG</abbr> remember passwords for a short time so that multiple files may be signed in one session, these instructions prevent Pinentry from hogging focus and preventing one from typing in other applications.
	this is exceedingly helpful if you need to type your password to unlock a password database and retrieve a password to unlock your <abbr title="Pretty Good Privacy">PGP</abbr> key.
</p>
<p>
	<abbr title="Lightweight X11 Desktop Environment">LXDE</abbr> requires a lot of work just to get into a usable state.
	Once there though, it seems to be a lot nicer than other desktops.
	Xfce on the other hand is very nice and configured pretty well by default, but it&apos;s impossible to configure it to behave reasonably in some ways.
	If <abbr title="Lightweight X11 Desktop Environment">LXDE</abbr> had a reasonable default configuration, I could actually recommend it to people, but as it is, I can&apos;t really do that.
	I can&apos;t recommend software that takes a lot of time and research; that just wouldn&apos;t be a nice thing for me to do.
</p>
<p>
	My primary election ballot came by post today.
	I should make sure to have it filled out and submitted by the sixteenth of this month.
	It&apos;s due by the seventeenth, but I don&apos;t have the full day to submit it both because it&apos;s due earlier in the day and because the public library (the nearest ballot drop box) isn&apos;t open all day.
	I need to research the candidates for most offices, I don&apos;t know anything about them.
	All that I currently know is that I need to vote against Clinton for the presidential nomination.
</p>
<p>
	I decided to try to <a href="https://copperhead.co/contact">contact the Copperhead team</a> to see if they use binary blobs in their operating system.
	However, their <abbr title="Pretty Good Privacy">PGP</abbr> key doesn&apos;t contain the email address that I needed to write to, so <a href="apt:evolution">Evolution</a> refused to encrypt the email.
	I needed to set up a more flexible mail client.
	I looked into <a href="apt:icedove">Icedove</a>, which I&apos;ve used in the past, but wasn&apos;t able to meet my needs before.
	Now, however, in addition to the availability of a plugin to provide <abbr title="Pretty Good Privacy">PGP</abbr> support, I found a plugin to provide CardDAV support.
	After setting up the connection to the server, I realized that I&apos;d forgotten to set the client up to use <abbr title="The Onion Router">Tor</abbr>, much to my frustration.
	Migrating my old local email database to the new email client was no walk in the park either.
	I found some <a href="https://support.mozilla.org./en-US/kb/switching-thunderbird">instructions</a> for making the switch, bu they didn&apos;t work.
	I finally found some <a href="http://kb.mozillazine.org./Thunderbird_:_FAQs_:_Migration#Specific_programs">newer information</a>, and as it turns out, <a href="apt:evolution">Evolution</a> used to use the same database format as Icedove, but Evolution has been updated to use a newer format that uses multiple smaller files instead of one large one.
	This seems like a better format to me just because the emails are easier to separate and if one is damaged, the rest could be fine.
	However, as Icedove is still using the older format, the email database needed to be converted before it could be imported.
	After much frustration, I finally found <a href="http://stackoverflow.com/questions/2501182/convert-maildir-to-mbox">this script</a>:
</p>
<blockquote><pre><code>#!/usr/bin/env python 
# -*- coding: utf-8 -*-
&quot;&quot;&quot;
Frédéric Grosshans, 19 January 2012
Nathan R.
	Yergler, 6 June 2010

This file does not contain sufficient creative expression to invoke
assertion of copyright.
	No warranty is expressed or implied; use at
your own risk.

---

Uses Python&apos;s included mailbox library to convert mail archives from
maildir [http://en.wikipedia.org/wiki/Maildir] to 
mbox [http://en.wikipedia.org/wiki/Mbox] format, icluding subfolder.

See http://docs.python.org/library/mailbox.html#mailbox.Mailbox for 
full documentation on this library.

---

To run, save as md2mb.py and run:

$ python md2mb.py [maildir_path] [mbox_filename]

[maildir_path] should be the the path to the actual maildir (containing new, 
cur, tmp, and the subfolders, which are hidden directories with names like 
.subfolde.subsubfolder.subsubsbfolder);

[mbox_filename] will be newly created, as well as a [mbox_filename].sbd the 
directory.
&quot;&quot;&quot;

import mailbox
import sys
import email
import os

def maildir2mailbox(maildirname, mboxfilename):
    &quot;&quot;&quot;
    slightly adapted from maildir2mbox.py, 
    Nathan R.
	Yergler, 6 June 2010
    http://yergler.net/blog/2010/06/06/batteries-included-or-maildir-to-mbox-again/


    &quot;&quot;&quot;
    # open the existing maildir and the target mbox file
    maildir = mailbox.Maildir(maildirname, email.message_from_file)
    mbox = mailbox.mbox(mboxfilename)

    # lock the mbox
    mbox.lock()

    # iterate over messages in the maildir and add to the mbox
    for msg in maildir:
        mbox.add(msg)

    # close and unlock
    mbox.close()
    maildir.close()

#Creates the main mailbox
dirname=sys.argv[-2]
mboxname=sys.argv[-1]
print(dirname +&apos; -&gt; &apos; +mboxname)
mboxdirname=mboxname+&apos;.sbd&apos;
maildir2mailbox(dirname,mboxname)
if not os.path.exists(mboxdirname): os.makedirs(mboxdirname)

listofdirs=[dn for dn in os.walk(dirname).next()[1] if dn not in [&apos;new&apos;, &apos;cur&apos;, &apos;tmp&apos;]]
for curfold in listofdirs:
    curlist=[mboxname]+curfold.split(&apos;.&apos;)
    curpath=os.path.join(*[dn+&apos;.sbd&apos; for dn in curlist if dn])
    if not os.path.exists(curpath): os.makedirs(curpath)
    print(&apos;| &apos; +curfold +&apos; -&gt; &apos;+curpath[:-4])
    maildir2mailbox(os.path.join(dirname,curfold),curpath[:-4])

print(&apos;Done&apos;)</code></pre></blockquote>
<p>
	Using that script converted the database very painlessly, though locating the script in the first place wasn&apos;t easy.
</p>
<p>
	With my email client set up, I sent my inquiry to the CopperheadOS team.
</p>
<p>
	While waiting for a response, I also asked if anyone in <a href="ircs://sbuk7aqcxkoyipwv.onion:49152/%23Replicant">#Replicant</a> knew anything.
	I specifically mentioned the &quot;optional Google service integration&quot;, and pab3 said that <a href="https://microg.org./">microG</a> could be used to integrate Google services without including proprietary components.
	I don&apos;t know for sure that this is what&apos;s being used to provide the integration though, I only know that it&apos;s a possibility.
</p>
<p>
	I should have finished the release of <a href="https://git.vola7ileiax4ueow.onion/y.st./include.d">include.d</a> today, but getting my email client set up took a lot of time.
	Maybe I&apos;ll get it done tomorrow.
</p>
		<hr/>
		<p>
			Copyright © 2016 Alex Yst;
			You may modify and/or redistribute this document under the terms of the <a rel="license" href="/license/gpl-3.0-standalone.xhtml"><abbr title="GNU&apos;s Not Unix">GNU</abbr> <abbr title="General Public License version Three or later">GPLv3+</abbr></a>.
			If for some reason you would prefer to modify and/or distribute this document under other free copyleft terms, please ask me via email.
			My address is in the source comments near the top of this document.
			This license also applies to embedded content such as images.
			For more information on that, see <a href="/en/a/licensing.xhtml">licensing</a>.
		</p>
		<p>
			<abbr title="World Wide Web Consortium">W3C</abbr> standards are important.
			This document conforms to the <a href="https://validator.w3.org./nu/?doc=https%3A%2F%2Fy.st.%2Fen%2Fweblog%2F2016%2F05-May%2F02.xhtml"><abbr title="Extensible Hypertext Markup Language">XHTML</abbr> 5.1</a> specification and uses style sheets that conform to the <a href="http://jigsaw.w3.org./css-validator/validator?uri=https%3A%2F%2Fy.st.%2Fen%2Fweblog%2F2016%2F05-May%2F02.xhtml"><abbr title="Cascading Style Sheets">CSS</abbr>3</a> specification.
		</p>
	</body>
</html>

